import request from '@/utils/request'

// 查询图纸变更列表
export function listDrawingChange(query) {
  return request({
    url: '/md/drawingChange/list',
    method: 'get',
    params: query
  })
}

// 查询图纸变更详细
export function getDrawingChange(id) {
  return request({
    url: '/md/drawingChange/' + id,
    method: 'get'
  })
}

// 新增图纸变更
export function addDrawingChange(data) {
  return request({
    url: '/md/drawingChange',
    method: 'post',
    data: data
  })
}

// 修改图纸变更
export function updateDrawingChange(data) {
  return request({
    url: '/md/drawingChange',
    method: 'put',
    data: data
  })
}

// 删除图纸变更
export function delDrawingChange(id) {
  return request({
    url: '/md/drawingChange/' + id,
    method: 'delete'
  })
}

// 查询任务列表
export function listBy(query) {
  return request({
    url: '/md/drawingChange/listBy',
    method: 'get',
    params: query
  })
}

// 根据code查询
export function selectByCode(changeCode) {
  return request({
    url: '/md/drawingChange/byCode/' + changeCode,
    method: 'get'
  })
}
